package com.pureut.system.mapper;

import com.pureut.system.domain.dto.MaterialFinishedDto;
import com.pureut.system.domain.MaterialFinished;
import com.pureut.system.domain.dto.ProjectRecursionDto;
import com.pureut.system.domain.vo.MaterialFinishedVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @Description
 * @Param
 * @Date
 * @Author hl
 **/
public interface MaterialFinishedMapper {

    /**
     * 查询成品信息
     */
    List<MaterialFinishedDto> selectFinishedList(MaterialFinishedVo materialFinished);

    /**
     * 新增成品信息
     */
    int insertFinished(MaterialFinished materialFinished);

    /**
     * 删除成品信息
     */
    int deleteFinishedById(String[] materialIdS);


    /**
     * 修改成品信息
     */
    int updateMaterialFinishedEdit(MaterialFinished materialFinished);

    /**
     * 冻结/解冻成品信息
     */
    int updateFinishedEditFreeze(MaterialFinished materialFinished);

    /**
     * 树结构
     */
    List<ProjectRecursionDto> selectChildrenFinishedThe();

    /**
     * 根据编码或名称查询对应id
     */
    MaterialFinished selectFinishedByList(MaterialFinished materialFinished);

    /**
     * 根据物料编码查询详情（成品信息）
     * @param materialCode
     * @return
     */
    MaterialFinished selectMaterialFinishedMaterialCode(String materialCode);

    /**
     * 根据id查询成品信息
     */
    String getFinishedById(@Param("materialIdList") List<String> materialIdList);

    /**
     * 根据物料编码查询详情(委外订单明细列表fegin调用)
     * @param materialCode
     * @return
     */
    MaterialFinishedDto getFinishViewByMaterialCode(String materialCode);
}
